import { Api, JsonRpc, RpcError } from 'eosjs'
import { JsSignatureProvider } from 'eosjs/dist/eosjs-jssig'

let config = {
  rpc: new JsonRpc('http://api.kylin.alohaeos.com', { fetch }),
  authorityProvider: new JsSignatureProvider(['5HvNc2K7HhmVTHUt5pL56hHxveX4EXGJn7UhNi6SSp1g7iwTAUD', '5KayvwbcS5m9Br8Ccc66BBnzsesNnPZhjqPq8gXxc9w4CSKnkwc' ]),
  chainId: '5fff1dae8dc8e2fc4d5b23b2c7665c97f9e9d8edf2b6485a86ba311c25639191',
  textDecoder: null,
  textEncoder: null
}
const eos = new Api(config)

const eos = new Api(config).rpc

export default eos
